#ifndef PWM_CONFIG_H
#define PWM_CONFIG_H

#include "board_config.h"
#include "device.h"

/*
 * as for parameter output io X
 * value 0xff means close corresponding output io
 */

#if defined(BOARD_CFG_PWM1)
#ifndef PMW1_CONFIG
#define PMW1_CONFIG                     \
{                                       \
    .pwm_device = RT_NULL,              \
    .output_ioA = 0,                    \
    .output_ioB = 0xff,                 \
    .name = "PWM1",                     \
}
#endif
#endif

#if defined(BOARD_CFG_PWM2)
#ifndef PMW2_CONFIG
#define PMW2_CONFIG                     \
{                                       \
    .pwm_device = RT_NULL,              \
    .output_ioA = 0,                    \
    .output_ioB = 0,                    \
    .name = "PWM2",                     \
}
#endif
#endif

#if defined(BOARD_CFG_PWM3)
#ifndef PMW3_CONFIG
#define PMW3_CONFIG                     \
{                                       \
    .pwm_device = RT_NULL,              \
    .output_ioA = 0,                    \
    .output_ioB = 0,                    \
    .name = "PWM3",                     \
}
#endif
#endif

#if defined(BOARD_CFG_PWM4)
#ifndef PMW4_CONFIG
#define PMW4_CONFIG                     \
{                                       \
    .pwm_device = RT_NULL,              \
    .output_ioA = 0,                    \
    .output_ioB = 0,                    \
    .name = "PWM4",                     \
}
#endif
#endif

#if defined(BOARD_CFG_PWM5)
#ifndef PMW5_CONFIG
#define PMW5_CONFIG                     \
{                                       \
    .pwm_device = RT_NULL,              \
    .output_ioA = 0,                    \
    .output_ioB = 0,                    \
    .name = "PWM5",                     \
}
#endif
#endif

#if defined(BOARD_CFG_PWM6)
#ifndef PMW6_CONFIG
#define PMW6_CONFIG                     \
{                                       \
    .pwm_device = RT_NULL,              \
    .output_ioA = 0,                    \
    .output_ioB = 0,                    \
    .name = "PWM6",                     \
}
#endif
#endif

#if defined(BOARD_CFG_PWM7)
#ifndef PMW7_CONFIG
#define PMW7_CONFIG                     \
{                                       \
    .pwm_device = RT_NULL,              \
    .output_ioA = 0,                    \
    .output_ioB = 0,                    \
    .name = "PWM7",                     \
}
#endif
#endif

#if defined(BOARD_CFG_PWM8)
#ifndef PMW8_CONFIG
#define PMW8_CONFIG                     \
{                                       \
    .pwm_device = RT_NULL,              \
    .output_ioA = 0,                    \
    .output_ioB = 0,                    \
    .name = "PWM8",                     \
}
#endif
#endif

#if defined(BOARD_CFG_PWM9)
#ifndef PMW9_CONFIG
#define PMW9_CONFIG                     \
{                                       \
    .pwm_device = RT_NULL,              \
    .output_ioA = 0,                    \
    .output_ioB = 0,                    \
    .name = "PWM9",                     \
}
#endif
#endif

#if defined(BOARD_CFG_PWM10)
#ifndef PMW10_CONFIG
#define PMW10_CONFIG                     \
{                                        \
    .pwm_device = RT_NULL,               \
    .output_ioA = 0,                     \
    .output_ioB = 0,                     \
    .name = "PWM10",                     \
}
#endif
#endif

#if defined(BOARD_CFG_PWM11)
#ifndef PMW11_CONFIG
#define PMW11_CONFIG                     \
{                                        \
    .pwm_device = RT_NULL,               \
    .output_ioA = 0,                     \
    .output_ioB = 0,                     \
    .name = "PWM11",                     \
}
#endif
#endif

#if defined(BOARD_CFG_PWM12)
#ifndef PMW12_CONFIG
#define PMW12_CONFIG                     \
{                                        \
    .pwm_device = RT_NULL,               \
    .output_ioA = 0,                     \
    .output_ioB = 0,                     \
    .name = "PWM12",                     \
}
#endif
#endif

#endif
